import { HouseListParams } from '@/types/house';
import { request } from '@umijs/max';

/** 获取房屋列表 */
export async function getHouseList(params: HouseListParams) {
  return request('/api/house/list', {
    method: 'GET',
    params,
  });
}

/** 曝光房屋 */
export async function exposeHouse(id: string) {
  return request('/api/house/expose', {
    method: 'POST',
    data: { id },
  });
}

/** 隐藏房屋 */
export async function hideHouse(id: string) {
  return request('/api/house/hide', {
    method: 'POST',
    data: { id },
  });
}
